-
-
Notifications
You must be signed in to change notification settings - Fork 212
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Forum perms shortcode templatization #5384
base: master
Are you sure you want to change the base?
Conversation
Code Climate has analyzed commit a50469c and detected 0 issues on this pull request. The test coverage on the diff in this pull request is 0.0% (80% is the threshold). This pull request will bring the total coverage in the repository to 39.3% (0.3% change). View more on Code Climate. |
|
||
return implode("<span class='forum-perms-separator'><!-- --></span>", $permDisplay); | ||
|
||
global $FORUM_VIEWFORUM_TEMPLATE; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using global is very PHP5. Please load the template. It can be done in the construct()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's the way the forum code is written. The template is already loaded in the main forum_view.php code, and for me it was a overload to load the template twice...
There's another way to do it. Pass the template via sc var, but that would require rewrite the main php file code....
Anyway all the forum code needs a major rewrite, it's poorly programmed...
If i'm allowed, i can do it...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, for quite some time I've been considering a rewrite from scratch of the forum plugin but while still keeping the same database structure.
We could start a rewrite as a new plugin in a separate repository. Then at some point it can be merged into core.
Motivation and Context
Remove harcoded HTML form PERMS forum shortcode
Description
Moved embebed HTML to template
How Has This Been Tested?
Tested in latest Github e107 code
Types of Changes
Checklist